import Vue from 'vue';
import VueRouter from 'vue-router';
Vue.use(VueRouter);

// 引入要跳转的组件
import Home from '../pages/home';
// import Feilei from '../pages/feilei';
import Gouwuche from '../pages/gouwuche';
// import My from '../pages/my';

// //引入404页面
// import Error404 from '../components/errorpage/404'
// 配置路由
const routes= [
    { path:'/',redirect: '/home' },
    {path:'/home',component:Home},
    // {path:'/feilei',component:Feilei},
    {path:'/gouwuche',component:Gouwuche},
    // {path:'/my',component:My},
    // { path: '*', component: Error404 },
   
]
// 实例化路由
const router =new VueRouter({
    routes,
    // 改变点击时的类名
    linkActiveClass:'active'
})
export default router;